package com.smarttest.portal.service.timertask.util;

import java.io.Serializable;
import java.util.Date;

/**
 * 类说明 ：
 * 
 * @author hanjiancheng@chinawayltd.com:
 * @version 创建时间：2010-5-19 下午02:28:40
 * 
 */

public class OutboxItem implements Serializable {

	private static final long serialVersionUID = -6727226462059097206L;

	private Integer id; // id
	private int level; // 级别
	private long userId; // 用户id
	private String msgId; // 短信ID
	private String channel; // 发送通道
	private String spno;
	private int cell;
	private String mobileNo; // 接收手机
	private String content; // 消息
	private Date createTime; // 创建时间
	private Date sendTime; // 发送时间
	private String source; // 来源
	private String encoding="7"; // 来源
	/**
	 * 0 成功
	 * 1 失败
	 */
	private int status;
	public static final int STATUS_SUCCESS = 0;
	public static final int STATUS_FAIL = 1;
	
	private boolean needRpt; // 是否需要report
	private int commPort;
	
	public static final String CHANNEL_KY = "ky";
	public static final String CHANNEL_DEFAULT = "default";
	public static final String CHANNEL_MODEM = "modem";
	
	private int type;
	
	public OutboxItem() {
	}

	public OutboxItem(int userId, String mobileNo, String content, String source,String channel,String encoding) {
		this.userId = userId;
		this.mobileNo = mobileNo;
		this.content = content;
		this.source = source;
		this.channel = channel;
		this.encoding = encoding;
		this.createTime = new Date();
	}

	public String getEncoding() {
		return encoding;
	}

	public void setEncoding(String encoding) {
		this.encoding = encoding;
	}

	public Integer getId() {
		return id;
	}

	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public int getLevel() {
		return level;
	}

	public void setLevel(int level) {
		this.level = level;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getMobileNo() {
		return mobileNo;
	}

	public void setMobileNo(String mobileNo) {
		this.mobileNo = mobileNo;
	}

	public String getMsgId() {
		return msgId;
	}

	public void setMsgId(String msgId) {
		this.msgId = msgId;
	}

	public boolean isNeedRpt() {
		return needRpt;
	}

	public void setNeedRpt(boolean needRpt) {
		this.needRpt = needRpt;
	}

	public long getUserId() {
		return userId;
	}

	public void setUserId(long userId) {
		this.userId = userId;
	}

	public Date getSendTime() {
		return sendTime;
	}

	public void setSendTime(Date sendTime) {
		this.sendTime = sendTime;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public String getChannel() {
		return channel;
	}

	public void setChannel(String channel) {
		this.channel = channel;
	}

	public String getSource() {
		return source;
	}

	public void setSource(String source) {
		this.source = source;
	}

	public String getSpno() {
		return spno;
	}

	public int getCell() {
		return cell;
	}

	public void setSpno(String spno) {
		this.spno = spno;
	}

	public int getType() {
		return type;
	}

	public void setType(int type) {
		this.type = type;
	}

	public void setCell(int cell) {
		this.cell = cell;
	}

	public int getCommPort() {
		return commPort;
	}

	public void setCommPort(int commPort) {
		this.commPort = commPort;
	}
}
